<?xml version="1.0" encoding="ascii"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
          "DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
  <title>netaddr.strategy.EUI48Strategy</title>
  <link rel="stylesheet" href="epydoc.css" type="text/css" />
  <script type="text/javascript" src="epydoc.js"></script>
</head>

<body bgcolor="white" text="black" link="blue" vlink="#204080"
      alink="#204080">
<!-- ==================== NAVIGATION BAR ==================== -->
<table class="navbar" border="0" width="100%" cellpadding="0"
       bgcolor="#a0c0ff" cellspacing="0">
  <tr valign="middle">
  <!-- Home link -->
      <th>&nbsp;&nbsp;&nbsp;<a
        href="netaddr-module.html">Home</a>&nbsp;&nbsp;&nbsp;</th>

  <!-- Tree link -->
      <th>&nbsp;&nbsp;&nbsp;<a
        href="module-tree.html">Trees</a>&nbsp;&nbsp;&nbsp;</th>

  <!-- Index link -->
      <th>&nbsp;&nbsp;&nbsp;<a
        href="identifier-index.html">Indices</a>&nbsp;&nbsp;&nbsp;</th>

  <!-- Help link -->
      <th>&nbsp;&nbsp;&nbsp;<a
        href="help.html">Help</a>&nbsp;&nbsp;&nbsp;</th>

  <!-- Project homepage -->
      <th class="navbar" align="right" width="100%">
        <table border="0" cellpadding="0" cellspacing="0">
          <tr><th class="navbar" align="center"
            ><a class="navbar" target="_top" href="http://netaddr.googlecode.com/">Project Homepage</a></th>
          </tr></table></th>
  </tr>
</table>
<table width="100%" cellpadding="0" cellspacing="0">
  <tr valign="top">
    <td width="100%">
      <span class="breadcrumbs">
        <a href="netaddr-module.html">Package&nbsp;netaddr</a> ::
        <a href="netaddr.strategy-module.html" onclick="show_private();">Module&nbsp;strategy</a> ::
        Class&nbsp;EUI48Strategy
      </span>
    </td>
    <td>
      <table cellpadding="0" cellspacing="0">
        <!-- hide/show private -->
        <tr><td align="right"><span class="options">[<a href="javascript:void(0);" class="privatelink"
    onclick="toggle_private();">hide&nbsp;private</a>]</span></td></tr>
        <tr><td align="right"><span class="options"
            >[<a href="frames.html" target="_top">frames</a
            >]&nbsp;|&nbsp;<a href="netaddr.strategy.EUI48Strategy-class.html"
            target="_top">no&nbsp;frames</a>]</span></td></tr>
      </table>
    </td>
  </tr>
</table>
<!-- ==================== CLASS DESCRIPTION ==================== -->
<h1 class="epydoc">Class EUI48Strategy</h1><p class="nomargin-top"><span class="codelink"><a href="netaddr.strategy-pysrc.html#EUI48Strategy">source&nbsp;code</a></span></p>
<pre class="base-tree">
  object --+    
           |    
<a href="netaddr.strategy.AddrStrategy-class.html">AddrStrategy</a> --+
               |
              <strong class="uidshort">EUI48Strategy</strong>
</pre>

<hr />
<p>Implements the operations that can be performed on an IEEE 48-bit EUI 
  (Extended Unique Identifer) a.k.a. a MAC (Media Access Control) layer 2 
  address.</p>
  <p>Supports all common (and some less common MAC string formats including
  Cisco's 'triple hextet' format and also bare MACs that contain no 
  delimiters.</p>

<!-- ==================== INSTANCE METHODS ==================== -->
<a name="section-InstanceMethods"></a>
<table class="summary" border="1" cellpadding="3"
       cellspacing="0" width="100%" bgcolor="white">
<tr bgcolor="#70b0f0" class="table-header">
  <td colspan="2" class="table-header">
    <table border="0" cellpadding="0" cellspacing="0" width="100%">
      <tr valign="top">
        <td align="left"><span class="table-header">Instance Methods</span></td>
        <td align="right" valign="top"
         ><span class="options">[<a href="#section-InstanceMethods"
         class="privatelink" onclick="toggle_private();"
         >hide private</a>]</span></td>
      </tr>
    </table>
  </td>
</tr>
<tr>
    <td width="15%" align="right" valign="top" class="summary">
      <span class="summary-type">&nbsp;</span>
    </td><td class="summary">
      <table width="100%" cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td><span class="summary-sig"><a href="netaddr.strategy.EUI48Strategy-class.html#__init__" class="summary-sig-name">__init__</a>(<span class="summary-sig-arg">self</span>,
        <span class="summary-sig-arg">word_fmt</span>=<span class="summary-sig-default"><code class="variable-quote">'</code><code class="variable-string">%.2X</code><code class="variable-quote">'</code></span>,
        <span class="summary-sig-arg">word_sep</span>=<span class="summary-sig-default"><code class="variable-quote">'</code><code class="variable-string">-</code><code class="variable-quote">'</code></span>)</span><br />
      Constructor.</td>
          <td align="right" valign="top">
            <span class="codelink"><a href="netaddr.strategy-pysrc.html#EUI48Strategy.__init__">source&nbsp;code</a></span>
            
          </td>
        </tr>
      </table>
      
    </td>
  </tr>
<tr>
    <td width="15%" align="right" valign="top" class="summary">
      <span class="summary-type">&nbsp;</span>
    </td><td class="summary">
      <table width="100%" cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td><span class="summary-sig"><a name="reset"></a><span class="summary-sig-name">reset</span>(<span class="summary-sig-arg">self</span>)</span><br />
      Resets the internal state of this strategy to safe default values.</td>
          <td align="right" valign="top">
            <span class="codelink"><a href="netaddr.strategy-pysrc.html#EUI48Strategy.reset">source&nbsp;code</a></span>
            
          </td>
        </tr>
      </table>
      
    </td>
  </tr>
<tr>
    <td width="15%" align="right" valign="top" class="summary">
      <span class="summary-type">&nbsp;</span>
    </td><td class="summary">
      <table width="100%" cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td><span class="summary-sig"><a href="netaddr.strategy.EUI48Strategy-class.html#valid_str" class="summary-sig-name">valid_str</a>(<span class="summary-sig-arg">self</span>,
        <span class="summary-sig-arg">addr</span>)</span><br />
      Returns:
      <code>True</code> if MAC address string is valid, <code>False</code> 
      otherwise.</td>
          <td align="right" valign="top">
            <span class="codelink"><a href="netaddr.strategy-pysrc.html#EUI48Strategy.valid_str">source&nbsp;code</a></span>
            
          </td>
        </tr>
      </table>
      
    </td>
  </tr>
<tr>
    <td width="15%" align="right" valign="top" class="summary">
      <span class="summary-type">&nbsp;</span>
    </td><td class="summary">
      <table width="100%" cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td><span class="summary-sig"><a href="netaddr.strategy.EUI48Strategy-class.html#str_to_int" class="summary-sig-name">str_to_int</a>(<span class="summary-sig-arg">self</span>,
        <span class="summary-sig-arg">addr</span>)</span><br />
      Returns:
      An unsigned integer that is equivalent to value represented by 
      EUI-48/MAC string address.</td>
          <td align="right" valign="top">
            <span class="codelink"><a href="netaddr.strategy-pysrc.html#EUI48Strategy.str_to_int">source&nbsp;code</a></span>
            
          </td>
        </tr>
      </table>
      
    </td>
  </tr>
<tr>
    <td width="15%" align="right" valign="top" class="summary">
      <span class="summary-type">&nbsp;</span>
    </td><td class="summary">
      <table width="100%" cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td><span class="summary-sig"><a href="netaddr.strategy.EUI48Strategy-class.html#int_to_str" class="summary-sig-name">int_to_str</a>(<span class="summary-sig-arg">self</span>,
        <span class="summary-sig-arg">int_val</span>,
        <span class="summary-sig-arg">word_sep</span>=<span class="summary-sig-default">None</span>,
        <span class="summary-sig-arg">word_fmt</span>=<span class="summary-sig-default">None</span>)</span><br />
      Returns:
      A MAC address in string form that is equivalent to value represented 
      by an unsigned integer.</td>
          <td align="right" valign="top">
            <span class="codelink"><a href="netaddr.strategy-pysrc.html#EUI48Strategy.int_to_str">source&nbsp;code</a></span>
            
          </td>
        </tr>
      </table>
      
    </td>
  </tr>
  <tr>
    <td colspan="2" class="summary">
    <p class="indent-wrapped-lines"><b>Inherited from <code>object</code></b>:
      <code>__delattr__</code>,
      <code>__getattribute__</code>,
      <code>__hash__</code>,
      <code>__new__</code>,
      <code>__reduce__</code>,
      <code>__reduce_ex__</code>,
      <code>__setattr__</code>,
      <code>__str__</code>
      </p>
    </td>
  </tr>
<tr bgcolor="#e8f0f8" >
  <th colspan="2" class="group-header"
    >&nbsp;&nbsp;&nbsp;&nbsp;Inherited from <a href="netaddr.strategy.AddrStrategy-class.html">AddrStrategy</a></th></tr>
<tr>
    <td width="15%" align="right" valign="top" class="summary">
      <span class="summary-type">&nbsp;</span>
    </td><td class="summary">
      <table width="100%" cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td><span class="summary-sig"><a href="netaddr.strategy.AddrStrategy-class.html#__repr__" class="summary-sig-name">__repr__</a>(<span class="summary-sig-arg">self</span>)</span><br />
      Returns:
      executable Python string to recreate equivalent object</td>
          <td align="right" valign="top">
            <span class="codelink"><a href="netaddr.strategy-pysrc.html#AddrStrategy.__repr__">source&nbsp;code</a></span>
            
          </td>
        </tr>
      </table>
      
    </td>
  </tr>
<tr>
    <td width="15%" align="right" valign="top" class="summary">
      <span class="summary-type">&nbsp;</span>
    </td><td class="summary">
      <table width="100%" cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td><span class="summary-sig"><a href="netaddr.strategy.AddrStrategy-class.html#bits_to_int" class="summary-sig-name">bits_to_int</a>(<span class="summary-sig-arg">self</span>,
        <span class="summary-sig-arg">bits</span>)</span><br />
      Returns:
      An unsigned integer that is equivalent to value represented by 
      network address in readable binary form.</td>
          <td align="right" valign="top">
            <span class="codelink"><a href="netaddr.strategy-pysrc.html#AddrStrategy.bits_to_int">source&nbsp;code</a></span>
            
          </td>
        </tr>
      </table>
      
    </td>
  </tr>
<tr>
    <td width="15%" align="right" valign="top" class="summary">
      <span class="summary-type">&nbsp;</span>
    </td><td class="summary">
      <table width="100%" cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td><span class="summary-sig"><a href="netaddr.strategy.AddrStrategy-class.html#int_to_bin" class="summary-sig-name">int_to_bin</a>(<span class="summary-sig-arg">self</span>,
        <span class="summary-sig-arg">int_val</span>)</span><br />
      Returns:
      A network address in standard binary representation format that is 
      equivalent to integer address value.</td>
          <td align="right" valign="top">
            <span class="codelink"><a href="netaddr.strategy-pysrc.html#AddrStrategy.int_to_bin">source&nbsp;code</a></span>
            
          </td>
        </tr>
      </table>
      
    </td>
  </tr>
<tr>
    <td width="15%" align="right" valign="top" class="summary">
      <span class="summary-type">&nbsp;</span>
    </td><td class="summary">
      <table width="100%" cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td><span class="summary-sig"><a href="netaddr.strategy.AddrStrategy-class.html#int_to_bits" class="summary-sig-name">int_to_bits</a>(<span class="summary-sig-arg">self</span>,
        <span class="summary-sig-arg">int_val</span>,
        <span class="summary-sig-arg">word_sep</span>=<span class="summary-sig-default">None</span>)</span><br />
      Returns:
      A network address in readable binary form that is equivalent to value
      represented by an unsigned integer.</td>
          <td align="right" valign="top">
            <span class="codelink"><a href="netaddr.strategy-pysrc.html#AddrStrategy.int_to_bits">source&nbsp;code</a></span>
            
          </td>
        </tr>
      </table>
      
    </td>
  </tr>
<tr>
    <td width="15%" align="right" valign="top" class="summary">
      <span class="summary-type">&nbsp;</span>
    </td><td class="summary">
      <table width="100%" cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td><span class="summary-sig"><a href="netaddr.strategy.AddrStrategy-class.html#int_to_packed" class="summary-sig-name">int_to_packed</a>(<span class="summary-sig-arg">self</span>,
        <span class="summary-sig-arg">int_val</span>)</span><br />
      Returns:
      a packed string that is equivalent to value represented by an 
      unsigned integer.</td>
          <td align="right" valign="top">
            <span class="codelink"><a href="netaddr.strategy-pysrc.html#AddrStrategy.int_to_packed">source&nbsp;code</a></span>
            
          </td>
        </tr>
      </table>
      
    </td>
  </tr>
<tr>
    <td width="15%" align="right" valign="top" class="summary">
      <span class="summary-type">&nbsp;</span>
    </td><td class="summary">
      <table width="100%" cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td><span class="summary-sig"><a href="netaddr.strategy.AddrStrategy-class.html#int_to_words" class="summary-sig-name">int_to_words</a>(<span class="summary-sig-arg">self</span>,
        <span class="summary-sig-arg">int_val</span>,
        <span class="summary-sig-arg">num_words</span>=<span class="summary-sig-default">None</span>,
        <span class="summary-sig-arg">word_size</span>=<span class="summary-sig-default">None</span>)</span></td>
          <td align="right" valign="top">
            <span class="codelink"><a href="netaddr.strategy-pysrc.html#AddrStrategy.int_to_words">source&nbsp;code</a></span>
            
          </td>
        </tr>
      </table>
      
    </td>
  </tr>
<tr>
    <td width="15%" align="right" valign="top" class="summary">
      <span class="summary-type">&nbsp;</span>
    </td><td class="summary">
      <table width="100%" cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td><span class="summary-sig"><a href="netaddr.strategy.AddrStrategy-class.html#packed_to_int" class="summary-sig-name">packed_to_int</a>(<span class="summary-sig-arg">self</span>,
        <span class="summary-sig-arg">packed_int</span>)</span><br />
      Returns:
      An unsigned integer equivalent to value of network address 
      represented by packed binary string.</td>
          <td align="right" valign="top">
            <span class="codelink"><a href="netaddr.strategy-pysrc.html#AddrStrategy.packed_to_int">source&nbsp;code</a></span>
            
          </td>
        </tr>
      </table>
      
    </td>
  </tr>
<tr>
    <td width="15%" align="right" valign="top" class="summary">
      <span class="summary-type">&nbsp;</span>
    </td><td class="summary">
      <table width="100%" cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td><span class="summary-sig"><a href="netaddr.strategy.AddrStrategy-class.html#valid_bits" class="summary-sig-name">valid_bits</a>(<span class="summary-sig-arg">self</span>,
        <span class="summary-sig-arg">bits</span>)</span><br />
      Returns:
      <code>True</code> if network address is valid for this address type, 
      <code>False</code> otherwise.</td>
          <td align="right" valign="top">
            <span class="codelink"><a href="netaddr.strategy-pysrc.html#AddrStrategy.valid_bits">source&nbsp;code</a></span>
            
          </td>
        </tr>
      </table>
      
    </td>
  </tr>
<tr>
    <td width="15%" align="right" valign="top" class="summary">
      <span class="summary-type">&nbsp;</span>
    </td><td class="summary">
      <table width="100%" cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td><span class="summary-sig"><a href="netaddr.strategy.AddrStrategy-class.html#valid_int" class="summary-sig-name">valid_int</a>(<span class="summary-sig-arg">self</span>,
        <span class="summary-sig-arg">int_val</span>)</span><br />
      Returns:
      <code>True</code> if integer falls within the boundaries of this 
      address type, <code>False</code> otherwise.</td>
          <td align="right" valign="top">
            <span class="codelink"><a href="netaddr.strategy-pysrc.html#AddrStrategy.valid_int">source&nbsp;code</a></span>
            
          </td>
        </tr>
      </table>
      
    </td>
  </tr>
<tr>
    <td width="15%" align="right" valign="top" class="summary">
      <span class="summary-type">&nbsp;</span>
    </td><td class="summary">
      <table width="100%" cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td><span class="summary-sig"><a href="netaddr.strategy.AddrStrategy-class.html#valid_words" class="summary-sig-name">valid_words</a>(<span class="summary-sig-arg">self</span>,
        <span class="summary-sig-arg">words</span>)</span><br />
      Returns:
      <code>True</code> if word sequence is valid for this address type, 
      <code>False</code> otherwise.</td>
          <td align="right" valign="top">
            <span class="codelink"><a href="netaddr.strategy-pysrc.html#AddrStrategy.valid_words">source&nbsp;code</a></span>
            
          </td>
        </tr>
      </table>
      
    </td>
  </tr>
<tr>
    <td width="15%" align="right" valign="top" class="summary">
      <span class="summary-type">&nbsp;</span>
    </td><td class="summary">
      <table width="100%" cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td><span class="summary-sig"><a href="netaddr.strategy.AddrStrategy-class.html#words_to_int" class="summary-sig-name">words_to_int</a>(<span class="summary-sig-arg">self</span>,
        <span class="summary-sig-arg">words</span>)</span><br />
      Returns:
      An unsigned integer that is equivalent to value represented by word 
      sequence.</td>
          <td align="right" valign="top">
            <span class="codelink"><a href="netaddr.strategy-pysrc.html#AddrStrategy.words_to_int">source&nbsp;code</a></span>
            
          </td>
        </tr>
      </table>
      
    </td>
  </tr>
</table>
<!-- ==================== CLASS VARIABLES ==================== -->
<a name="section-ClassVariables"></a>
<table class="summary" border="1" cellpadding="3"
       cellspacing="0" width="100%" bgcolor="white">
<tr bgcolor="#70b0f0" class="table-header">
  <td colspan="2" class="table-header">
    <table border="0" cellpadding="0" cellspacing="0" width="100%">
      <tr valign="top">
        <td align="left"><span class="table-header">Class Variables</span></td>
        <td align="right" valign="top"
         ><span class="options">[<a href="#section-ClassVariables"
         class="privatelink" onclick="toggle_private();"
         >hide private</a>]</span></td>
      </tr>
    </table>
  </td>
</tr>
<tr>
    <td width="15%" align="right" valign="top" class="summary">
      <span class="summary-type">&nbsp;</span>
    </td><td class="summary">
        <a href="netaddr.strategy.EUI48Strategy-class.html#RE_MAC_FORMATS" class="summary-name">RE_MAC_FORMATS</a> = <code title="[re.compile(r'(?i)^([0-9A-F]{1,2}):([0-9A-F]{1,2}):([0-9A-F]{1,2}):([0\
-9A-F]{1,2}):([0-9A-F]{1,2}):([0-9A-F]{1,2})$'),
 re.compile(r'(?i)^([0-9A-F]{1,2})-([0-9A-F]{1,2})-([0-9A-F]{1,2})-([0\
-9A-F]{1,2})-([0-9A-F]{1,2})-([0-9A-F]{1,2})$'),
 re.compile(r'(?i)^([0-9A-F]{1,4}):([0-9A-F]{1,4}):([0-9A-F]{1,4})$'),
 re.compile(r'(?i)^([0-9A-F]{1,4})-([0-9A-F]{1,4})-([0-9A-F]{1,4})$'),
 re.compile(r'(?i)^([0-9A-F]{5,6})-([0-9A-F]{5,6})$'),
 re.compile(r'(?i)^([0-9A-F]{5,6}):([0-9A-F]{5,6})$'),
..."><code class="variable-group">[</code>re.compile(r'<code class="re-flags">(?i)</code>^<code class="re-group">(</code><code class="re-group">[</code>0<code class="re-op">-</code>9A<code class="re-op">-</code>F<code class="re-group">]</code><code class="re-op">{1,2}</code><code class="re-group">)</code>:<code class="re-group">(</code><code class="re-group">[</code>0<code class="re-op">-</code>9A<code class="re-op">-</code>F<code class="re-group">]</code><code class="re-op">{</code><code class="variable-ellipsis">...</code></code>
    </td>
  </tr>
<tr>
    <td width="15%" align="right" valign="top" class="summary">
      <span class="summary-type">&nbsp;</span>
    </td><td class="summary">
        <a href="netaddr.strategy.EUI48Strategy-class.html#_" class="summary-name">_</a> = <code title="'^([0-9A-F][0-9A-F][0-9A-F][0-9A-F][0-9A-F][0-9A-F][0-9A-F][0-9A-F][0-\
9A-F][0-9A-F][0-9A-F])$'"><code class="variable-quote">'</code><code class="variable-string">^([0-9A-F][0-9A-F][0-9A-F][0-9A-F][0-9A-F][0-9A-F][0-9A-F</code><code class="variable-ellipsis">...</code></code>
    </td>
  </tr>
<tr bgcolor="#e8f0f8" >
  <th colspan="2" class="group-header"
    >&nbsp;&nbsp;&nbsp;&nbsp;Inherited from <a href="netaddr.strategy.AddrStrategy-class.html">AddrStrategy</a></th></tr>
<tr>
    <td width="15%" align="right" valign="top" class="summary">
      <span class="summary-type">&nbsp;</span>
    </td><td class="summary">
        <a name="STRUCT_FORMATS"></a><span class="summary-name">STRUCT_FORMATS</span> = <code title="{8: 'B', 16: 'H', 32: 'I'}"><code class="variable-group">{</code>8<code class="variable-op">: </code><code class="variable-quote">'</code><code class="variable-string">B</code><code class="variable-quote">'</code><code class="variable-op">, </code>16<code class="variable-op">: </code><code class="variable-quote">'</code><code class="variable-string">H</code><code class="variable-quote">'</code><code class="variable-op">, </code>32<code class="variable-op">: </code><code class="variable-quote">'</code><code class="variable-string">I</code><code class="variable-quote">'</code><code class="variable-group">}</code></code><br />
      Lookup table for struct module format strings.
    </td>
  </tr>
</table>
<!-- ==================== PROPERTIES ==================== -->
<a name="section-Properties"></a>
<table class="summary" border="1" cellpadding="3"
       cellspacing="0" width="100%" bgcolor="white">
<tr bgcolor="#70b0f0" class="table-header">
  <td colspan="2" class="table-header">
    <table border="0" cellpadding="0" cellspacing="0" width="100%">
      <tr valign="top">
        <td align="left"><span class="table-header">Properties</span></td>
        <td align="right" valign="top"
         ><span class="options">[<a href="#section-Properties"
         class="privatelink" onclick="toggle_private();"
         >hide private</a>]</span></td>
      </tr>
    </table>
  </td>
</tr>
  <tr>
    <td colspan="2" class="summary">
    <p class="indent-wrapped-lines"><b>Inherited from <code>object</code></b>:
      <code>__class__</code>
      </p>
    </td>
  </tr>
</table>
<!-- ==================== METHOD DETAILS ==================== -->
<a name="section-MethodDetails"></a>
<table class="details" border="1" cellpadding="3"
       cellspacing="0" width="100%" bgcolor="white">
<tr bgcolor="#70b0f0" class="table-header">
  <td colspan="2" class="table-header">
    <table border="0" cellpadding="0" cellspacing="0" width="100%">
      <tr valign="top">
        <td align="left"><span class="table-header">Method Details</span></td>
        <td align="right" valign="top"
         ><span class="options">[<a href="#section-MethodDetails"
         class="privatelink" onclick="toggle_private();"
         >hide private</a>]</span></td>
      </tr>
    </table>
  </td>
</tr>
</table>
<a name="__init__"></a>
<div>
<table class="details" border="1" cellpadding="3"
       cellspacing="0" width="100%" bgcolor="white">
<tr><td>
  <table width="100%" cellpadding="0" cellspacing="0" border="0">
  <tr valign="top"><td>
  <h3 class="epydoc"><span class="sig"><span class="sig-name">__init__</span>(<span class="sig-arg">self</span>,
        <span class="sig-arg">word_fmt</span>=<span class="sig-default"><code class="variable-quote">'</code><code class="variable-string">%.2X</code><code class="variable-quote">'</code></span>,
        <span class="sig-arg">word_sep</span>=<span class="sig-default"><code class="variable-quote">'</code><code class="variable-string">-</code><code class="variable-quote">'</code></span>)</span>
    <br /><em class="fname">(Constructor)</em>
  </h3>
  </td><td align="right" valign="top"
    ><span class="codelink"><a href="netaddr.strategy-pysrc.html#EUI48Strategy.__init__">source&nbsp;code</a></span>&nbsp;
    </td>
  </tr></table>
  
  <p>Constructor.</p>
  <dl class="fields">
    <dt>Parameters:</dt>
    <dd><ul class="nomargin-top">
        <li><strong class="pname"><code>word_sep</code></strong> - separator between each word. (Default: '-')</li>
        <li><strong class="pname"><code>word_fmt</code></strong> - format string for each hextet. (Default: '%02x')</li>
    </ul></dd>
    <dt>Overrides:
        object.__init__
    </dt>
  </dl>
</td></tr></table>
</div>
<a name="valid_str"></a>
<div>
<table class="details" border="1" cellpadding="3"
       cellspacing="0" width="100%" bgcolor="white">
<tr><td>
  <table width="100%" cellpadding="0" cellspacing="0" border="0">
  <tr valign="top"><td>
  <h3 class="epydoc"><span class="sig"><span class="sig-name">valid_str</span>(<span class="sig-arg">self</span>,
        <span class="sig-arg">addr</span>)</span>
  </h3>
  </td><td align="right" valign="top"
    ><span class="codelink"><a href="netaddr.strategy-pysrc.html#EUI48Strategy.valid_str">source&nbsp;code</a></span>&nbsp;
    </td>
  </tr></table>
  
  
  <dl class="fields">
    <dt>Parameters:</dt>
    <dd><ul class="nomargin-top">
        <li><strong class="pname"><code>addr</code></strong> - An EUI-48 or MAC address in string form.</li>
    </ul></dd>
    <dt>Returns:</dt>
        <dd><code>True</code> if MAC address string is valid, 
          <code>False</code> otherwise.</dd>
    <dt>Overrides:
        <a href="netaddr.strategy.AddrStrategy-class.html#valid_str">AddrStrategy.valid_str</a>
    </dt>
  </dl>
</td></tr></table>
</div>
<a name="str_to_int"></a>
<div>
<table class="details" border="1" cellpadding="3"
       cellspacing="0" width="100%" bgcolor="white">
<tr><td>
  <table width="100%" cellpadding="0" cellspacing="0" border="0">
  <tr valign="top"><td>
  <h3 class="epydoc"><span class="sig"><span class="sig-name">str_to_int</span>(<span class="sig-arg">self</span>,
        <span class="sig-arg">addr</span>)</span>
  </h3>
  </td><td align="right" valign="top"
    ><span class="codelink"><a href="netaddr.strategy-pysrc.html#EUI48Strategy.str_to_int">source&nbsp;code</a></span>&nbsp;
    </td>
  </tr></table>
  
  
  <dl class="fields">
    <dt>Parameters:</dt>
    <dd><ul class="nomargin-top">
        <li><strong class="pname"><code>addr</code></strong> - An EUI-48 or MAC address in string form.</li>
    </ul></dd>
    <dt>Returns:</dt>
        <dd>An unsigned integer that is equivalent to value represented by 
          EUI-48/MAC string address.</dd>
    <dt>Overrides:
        <a href="netaddr.strategy.AddrStrategy-class.html#str_to_int">AddrStrategy.str_to_int</a>
    </dt>
  </dl>
</td></tr></table>
</div>
<a name="int_to_str"></a>
<div>
<table class="details" border="1" cellpadding="3"
       cellspacing="0" width="100%" bgcolor="white">
<tr><td>
  <table width="100%" cellpadding="0" cellspacing="0" border="0">
  <tr valign="top"><td>
  <h3 class="epydoc"><span class="sig"><span class="sig-name">int_to_str</span>(<span class="sig-arg">self</span>,
        <span class="sig-arg">int_val</span>,
        <span class="sig-arg">word_sep</span>=<span class="sig-default">None</span>,
        <span class="sig-arg">word_fmt</span>=<span class="sig-default">None</span>)</span>
  </h3>
  </td><td align="right" valign="top"
    ><span class="codelink"><a href="netaddr.strategy-pysrc.html#EUI48Strategy.int_to_str">source&nbsp;code</a></span>&nbsp;
    </td>
  </tr></table>
  
  
  <dl class="fields">
    <dt>Parameters:</dt>
    <dd><ul class="nomargin-top">
        <li><strong class="pname"><code>int_val</code></strong> - An unsigned integer.</li>
        <li><strong class="pname"><code>word_sep</code></strong> - (optional) The separator used between words in an address string.</li>
        <li><strong class="pname"><code>word_fmt</code></strong> - (optional) A Python format string used to format each word of 
          address.</li>
    </ul></dd>
    <dt>Returns:</dt>
        <dd>A MAC address in string form that is equivalent to value 
          represented by an unsigned integer.</dd>
    <dt>Overrides:
        <a href="netaddr.strategy.AddrStrategy-class.html#int_to_str">AddrStrategy.int_to_str</a>
    </dt>
  </dl>
</td></tr></table>
</div>
<br />
<!-- ==================== CLASS VARIABLE DETAILS ==================== -->
<a name="section-ClassVariableDetails"></a>
<table class="details" border="1" cellpadding="3"
       cellspacing="0" width="100%" bgcolor="white">
<tr bgcolor="#70b0f0" class="table-header">
  <td colspan="2" class="table-header">
    <table border="0" cellpadding="0" cellspacing="0" width="100%">
      <tr valign="top">
        <td align="left"><span class="table-header">Class Variable Details</span></td>
        <td align="right" valign="top"
         ><span class="options">[<a href="#section-ClassVariableDetails"
         class="privatelink" onclick="toggle_private();"
         >hide private</a>]</span></td>
      </tr>
    </table>
  </td>
</tr>
</table>
<a name="RE_MAC_FORMATS"></a>
<div>
<table class="details" border="1" cellpadding="3"
       cellspacing="0" width="100%" bgcolor="white">
<tr><td>
  <h3 class="epydoc">RE_MAC_FORMATS</h3>
  
  <dl class="fields">
  </dl>
  <dl class="fields">
    <dt>Value:</dt>
      <dd><table><tr><td><pre class="variable">
<code class="variable-group">[</code>re.compile(r'<code class="re-flags">(?i)</code>^<code class="re-group">(</code><code class="re-group">[</code>0<code class="re-op">-</code>9A<code class="re-op">-</code>F<code class="re-group">]</code><code class="re-op">{1,2}</code><code class="re-group">)</code>:<code class="re-group">(</code><code class="re-group">[</code>0<code class="re-op">-</code>9A<code class="re-op">-</code>F<code class="re-group">]</code><code class="re-op">{1,2}</code><code class="re-group">)</code>:<code class="re-group">(</code><code class="re-group">[</code>0<code class="re-op">-</code>9A<code class="re-op">-</code>F<code class="re-group">]</code><code class="re-op">{1,2}</code><code class="re-group">)</code>:<code class="re-group">(</code><code class="re-group">[</code>0<code class="re-op"></code><span class="variable-linewrap"><img src="crarr.png" alt="\" /></span>
<code class="re-op">-</code>9A<code class="re-op">-</code>F<code class="re-group">]</code><code class="re-op">{1,2}</code><code class="re-group">)</code>:<code class="re-group">(</code><code class="re-group">[</code>0<code class="re-op">-</code>9A<code class="re-op">-</code>F<code class="re-group">]</code><code class="re-op">{1,2}</code><code class="re-group">)</code>:<code class="re-group">(</code><code class="re-group">[</code>0<code class="re-op">-</code>9A<code class="re-op">-</code>F<code class="re-group">]</code><code class="re-op">{1,2}</code><code class="re-group">)</code>$')<code class="variable-op">,</code>
 re.compile(r'<code class="re-flags">(?i)</code>^<code class="re-group">(</code><code class="re-group">[</code>0<code class="re-op">-</code>9A<code class="re-op">-</code>F<code class="re-group">]</code><code class="re-op">{1,2}</code><code class="re-group">)</code>-<code class="re-group">(</code><code class="re-group">[</code>0<code class="re-op">-</code>9A<code class="re-op">-</code>F<code class="re-group">]</code><code class="re-op">{1,2}</code><code class="re-group">)</code>-<code class="re-group">(</code><code class="re-group">[</code>0<code class="re-op">-</code>9A<code class="re-op">-</code>F<code class="re-group">]</code><code class="re-op">{1,2}</code><code class="re-group">)</code>-<code class="re-group">(</code><code class="re-group">[</code>0<code class="re-op"></code><span class="variable-linewrap"><img src="crarr.png" alt="\" /></span>
<code class="re-op">-</code>9A<code class="re-op">-</code>F<code class="re-group">]</code><code class="re-op">{1,2}</code><code class="re-group">)</code>-<code class="re-group">(</code><code class="re-group">[</code>0<code class="re-op">-</code>9A<code class="re-op">-</code>F<code class="re-group">]</code><code class="re-op">{1,2}</code><code class="re-group">)</code>-<code class="re-group">(</code><code class="re-group">[</code>0<code class="re-op">-</code>9A<code class="re-op">-</code>F<code class="re-group">]</code><code class="re-op">{1,2}</code><code class="re-group">)</code>$')<code class="variable-op">,</code>
 re.compile(r'<code class="re-flags">(?i)</code>^<code class="re-group">(</code><code class="re-group">[</code>0<code class="re-op">-</code>9A<code class="re-op">-</code>F<code class="re-group">]</code><code class="re-op">{1,4}</code><code class="re-group">)</code>:<code class="re-group">(</code><code class="re-group">[</code>0<code class="re-op">-</code>9A<code class="re-op">-</code>F<code class="re-group">]</code><code class="re-op">{1,4}</code><code class="re-group">)</code>:<code class="re-group">(</code><code class="re-group">[</code>0<code class="re-op">-</code>9A<code class="re-op">-</code>F<code class="re-group">]</code><code class="re-op">{1,4}</code><code class="re-group">)</code>$')<code class="variable-op">,</code>
 re.compile(r'<code class="re-flags">(?i)</code>^<code class="re-group">(</code><code class="re-group">[</code>0<code class="re-op">-</code>9A<code class="re-op">-</code>F<code class="re-group">]</code><code class="re-op">{1,4}</code><code class="re-group">)</code>-<code class="re-group">(</code><code class="re-group">[</code>0<code class="re-op">-</code>9A<code class="re-op">-</code>F<code class="re-group">]</code><code class="re-op">{1,4}</code><code class="re-group">)</code>-<code class="re-group">(</code><code class="re-group">[</code>0<code class="re-op">-</code>9A<code class="re-op">-</code>F<code class="re-group">]</code><code class="re-op">{1,4}</code><code class="re-group">)</code>$')<code class="variable-op">,</code>
 re.compile(r'<code class="re-flags">(?i)</code>^<code class="re-group">(</code><code class="re-group">[</code>0<code class="re-op">-</code>9A<code class="re-op">-</code>F<code class="re-group">]</code><code class="re-op">{5,6}</code><code class="re-group">)</code>-<code class="re-group">(</code><code class="re-group">[</code>0<code class="re-op">-</code>9A<code class="re-op">-</code>F<code class="re-group">]</code><code class="re-op">{5,6}</code><code class="re-group">)</code>$')<code class="variable-op">,</code>
 re.compile(r'<code class="re-flags">(?i)</code>^<code class="re-group">(</code><code class="re-group">[</code>0<code class="re-op">-</code>9A<code class="re-op">-</code>F<code class="re-group">]</code><code class="re-op">{5,6}</code><code class="re-group">)</code>:<code class="re-group">(</code><code class="re-group">[</code>0<code class="re-op">-</code>9A<code class="re-op">-</code>F<code class="re-group">]</code><code class="re-op">{5,6}</code><code class="re-group">)</code>$')<code class="variable-op">,</code>
<code class="variable-ellipsis">...</code>
</pre></td></tr></table>
</dd>
  </dl>
</td></tr></table>
</div>
<a name="_"></a>
<div>
<table class="details" border="1" cellpadding="3"
       cellspacing="0" width="100%" bgcolor="white">
<tr><td>
  <h3 class="epydoc">_</h3>
  
  <dl class="fields">
  </dl>
  <dl class="fields">
    <dt>Value:</dt>
      <dd><table><tr><td><pre class="variable">
<code class="variable-quote">'</code><code class="variable-string">^([0-9A-F][0-9A-F][0-9A-F][0-9A-F][0-9A-F][0-9A-F][0-9A-F][0-9A-F][0-</code><span class="variable-linewrap"><img src="crarr.png" alt="\" /></span>
<code class="variable-string">9A-F][0-9A-F][0-9A-F])$</code><code class="variable-quote">'</code>
</pre></td></tr></table>
</dd>
  </dl>
</td></tr></table>
</div>
<br />
<!-- ==================== NAVIGATION BAR ==================== -->
<table class="navbar" border="0" width="100%" cellpadding="0"
       bgcolor="#a0c0ff" cellspacing="0">
  <tr valign="middle">
  <!-- Home link -->
      <th>&nbsp;&nbsp;&nbsp;<a
        href="netaddr-module.html">Home</a>&nbsp;&nbsp;&nbsp;</th>

  <!-- Tree link -->
      <th>&nbsp;&nbsp;&nbsp;<a
        href="module-tree.html">Trees</a>&nbsp;&nbsp;&nbsp;</th>

  <!-- Index link -->
      <th>&nbsp;&nbsp;&nbsp;<a
        href="identifier-index.html">Indices</a>&nbsp;&nbsp;&nbsp;</th>

  <!-- Help link -->
      <th>&nbsp;&nbsp;&nbsp;<a
        href="help.html">Help</a>&nbsp;&nbsp;&nbsp;</th>

  <!-- Project homepage -->
      <th class="navbar" align="right" width="100%">
        <table border="0" cellpadding="0" cellspacing="0">
          <tr><th class="navbar" align="center"
            ><a class="navbar" target="_top" href="http://netaddr.googlecode.com/">Project Homepage</a></th>
          </tr></table></th>
  </tr>
</table>
<table border="0" cellpadding="0" cellspacing="0" width="100%%">
  <tr>
    <td align="left" class="footer">
    Generated by Epydoc 3.0.1 on Mon Apr 13 15:14:41 2009
    </td>
    <td align="right" class="footer">
      <a target="mainFrame" href="http://epydoc.sourceforge.net"
        >http://epydoc.sourceforge.net</a>
    </td>
  </tr>
</table>

<script type="text/javascript">
  <!--
  // Private objects are initially displayed (because if
  // javascript is turned off then we want them to be
  // visible); but by default, we want to hide them.  So hide
  // them unless we have a cookie that says to show them.
  checkCookie();
  // -->
</script>
</body>
</html>
